home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 4 / Apprentice-Release4.iso / Demos / AppMaker 2.0b3 / Demo AppMaker 1.5 / Demo AppMaker™ / Demo AppMaker™.rsrc / TmPT_107_ModelessDialog < prev    next >
Encoding:
Text File  |  1992-04-08  |  1.9 KB  |  93 lines

  1. { %filename% -- modeless dialog }
  2. { Created %date% %time% by AppMaker }
  3.  
  4. {    This module overrides the AppMaker-generated code in z%dlogname%.%        %}
  5. {    It provides a place for you to add your own code and still be able to    }
  6. {    generate code for new changes to the user interface.  This module will    }
  7. {    not be regenerated by AppMaker unless you delete it.  Its superclass,    }
  8. {    z%dlogname%, may be regenerated to handle user interface changes%        %}
  9. {    without losing your hand-coded changes to this module.                    }
  10.  
  11. Unit %unitname%;
  12. Interface
  13.  
  14. Uses
  15.     TCL,
  16.     AMCL,
  17.     %AppName%Intf;
  18.  
  19. {----------}
  20. Function MakeNew%dlogname%    (aSupervisor:    CDirectorOwner): C%dlogname%;
  21.  
  22. {----------}
  23. Implementation
  24.  
  25. %for each item gen defineItem%
  26.  
  27. {----------}
  28. Function MakeNew%dlogname%    (aSupervisor:    CDirectorOwner): C%dlogname%;
  29. var
  30.     dialog:            C%dlogname%;
  31.     fi:                FailInfo;
  32.  
  33.     {----------}
  34.     Procedure HandleFailure    (error:        Integer;
  35.                              message:    Longint);
  36.     Begin
  37.         ForgetObject (dialog);
  38.     End;
  39.  
  40. Begin
  41.     dialog := nil;
  42.     CatchFailures (fi, HandleFailure);
  43.  
  44.     New (dialog);
  45.     dialog.I%dlogname% (aSupervisor);
  46.  
  47.     {initialize dialog panes}
  48.  
  49.     Success;
  50.     MakeNew%dlogname% := dialog;
  51. End; {MakeNew%dlogname%}
  52.  
  53. {----------}
  54. Procedure C%dlogname%.I%dlogname%    (aSupervisor:    CDirectorOwner);
  55. Begin
  56.     inherited IZ%dlogname% (aSupervisor);
  57.  
  58.     {any additional initialization for your dialog}
  59.  
  60. End; {I%dlogname%}
  61.  
  62. %for each item gen auxiliaryMethod%
  63. {----------}
  64. Procedure C%dlogname%.UpdateMenus;
  65. Begin
  66.     inherited UpdateMenus;
  67.  
  68. End; {UpdateMenus}
  69.  
  70. {----------}
  71. Procedure C%dlogname%.DoCommand    (theCommand: longint);
  72. Begin
  73.     case theCommand of
  74.         0:    ;
  75.         %for each item gen DoCommand%
  76.  
  77.         otherwise
  78.             inherited DoCommand (theCommand);
  79.     end; {case}
  80. End; {DoCommand}
  81.     
  82. {----------}
  83. Procedure C%dlogname%.ProviderChanged%    %(aProvider:    CCollaborator;
  84.                                          reason:        longint;
  85.                                          info:            univ Ptr);
  86.  
  87. Begin
  88.     %for each item gen ProviderChanged%
  89.  
  90. End; {ProviderChanged}
  91.  
  92. End. {%unitname%}
  93.